<script>
    var pnum = {$pnum};
    {if condition = "(isset($filter)) AND ($filter)"}
    var filter = {$filter};
    {/if}
    {if condition = "(!isset($search)) OR (!$search)"}
    var search = 0;
    var goUrl = "/{$Request.module}/distribution_withdraw/lst/filter/" + filter + ".html?page=" + pnum;
    {else /}
    var search = {$search};
    var goUrl = "/{$Request.module}/distribution_withdraw/search.html?page=" + pnum;
    {/if}
</script>    
<table class="table table-hover table-bordered">
    <thead>
        <tr>
            <th style="width:20%">流水单号</th>
            <th>分销商姓名</th>
            <th>手机号</th>
            <th>申请时间</th>
            <th>提现金额</th>
            <th>状态</th>
            <th>操作</th>
        </tr>
    </thead>
    <tbody>
        {if condition="$list->isEmpty() == false"}
        {foreach name="list" item="v"} 
        <tr>
            <td>{$v.tx_number}</td>
            <td>{$v.real_name}</td>
            <td>{$v.phone}</td>
            <td>{$v.create_time}</td>
            <td>{$v.amount}</td>
            <td>
                {if condition="($v['status'] eq 0) AND ($v['pay_status'] eq 0)"}
                    <span style="color:#1c84c6;">待审核</span>
                {elseif condition="($v['status'] eq 1) AND ($v['pay_status'] eq 0)"/}
                    <span style="color:#1c84c6;">待打款</span>
                {elseif condition="($v['status'] eq 1) AND ($v['pay_status'] eq 1)"/}
                    <span style="color:#1992FC;">已完成</span>
                {elseif condition="($v['status'] eq 1) AND ($v['pay_status'] eq 2)"/}
                    <span style="color:#ed5565;">打款失败</span>
                {elseif condition="($v['status'] eq 2) AND ($v['pay_status'] eq 0)"/}
                    <span style="color:#ed5565;">审核未通过</span>
                {/if}
            </td>
            <td>
                {if condition="($v['status'] eq 0) AND ($v['pay_status'] eq 0)"}
                    <button type="button" class="btn btn-success btn-xs" onclick="tixianchecked({$v.id}, this);">
                        <i class="fa fa-paste"></i>&nbsp;审核
                    </button>
                {elseif condition="($v['status'] eq 1) AND ($v['pay_status'] eq 0)"/}
                    <button type="button" class="btn btn-primary btn-xs" onclick="dakuan({$v.id}, this);">
                        <i class="fa fa-pencil"></i>&nbsp;打款
                    </button>
                {else/}
                    <button type="button" class="btn btn-info btn-xs" onclick="tixianinfo({$v.id}, this);">
                        <i class="fa fa-paste"></i>&nbsp;详细
                    </button>
                {/if}
            </td>
        </tr>
        {/foreach}
        {else/}
        <tr><td colspan="7" style="text-align:center; font-size:14px;">没有找到相关数据</td></tr>
        {/if}						
    </tbody>
</table>
<div class="row"><div class="pagination" style="float:right; margin-right:20px;">{$page}</div></div>